package edu.neu.ecommerceplatform.mapper;

import edu.neu.ecommerceplatform.model.Order;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import edu.neu.ecommerceplatform.dto.SpenderInfo;

import java.util.List;

@Mapper
public interface OrderMapper {
    Order findById(Integer id);
    List<Order> findAll();
    void save(Order order);
    void update(Order order);
    void delete(Integer id);
    List<Order> findByCustomerId(Integer customerId);
    SpenderInfo findTopSpenderToday();
    List<Order> findByCustomerIdAndDate(@Param("customerId") Integer customerId, @Param("date") String date);
} 